package de.uni_mannheim.informatik.ai.dame_ai.dame.domain;

public class Piece {
	public static final short EMPTY =4;
	public static final short WHITE =0;
	public static final short WHITEDAME =1;
	public static final short BLACK =2;
	public static final short BLACKDAME =3;
	protected short type;
	/**
	 * This Creates a Piece which can be placed on a square
	 * @param type The type of piece
	 */
	public Piece(short type) {
		super();
		this.type = type;
	}
	public short getType() {
		return type;
	}
	public Piece(Piece piece){
		this.type = piece.getType();
	}
	@Override
	public boolean equals(Object obj) {
		if(obj instanceof Piece){
			Piece temp = (Piece)obj;
			if(type == temp.type){
				return true;
			} else return false;
		} else return false;
	}
	public void setType(short type) {
		this.type = type;
	}
	
	
}
